package com.sq.ai.entry;

import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;

import java.util.List;

/**
 * @Author Li sir
 * @Date 2023/9/20
 */
@Data
public class ChannelConfig {

    @ApiModelProperty("设备sn号")
    private String deviceId;

    @ApiModelProperty("通道号")
    private String channelId;

    @ApiModelProperty("视频流")
    private String rtmpUrl;

    @ApiModelProperty("算法配置")
    private List<Pipelines> pipelines;

    @Data
    public static class Pipelines{

        @ApiModelProperty("比对阈值")
        private double threshold;

        @ApiModelProperty("算法代号")
        private String modelId;

        @ApiModelProperty("识别roi")
        private Roi roi;

    }

    @Data
    @ToString
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Roi{

        private Integer x;

        private Integer y;

        private Integer w;

        private Integer h;

    }

}
